import com.xe.core.XEResource
String path = req.getServletPath()
boolean srv=path!=null && !path.equalsIgnoreCase("/ExtremeEngine/service.groovy")
def out = { resp.getWriter().write(it)}
out(path +"<br>")
if (srv)
{
  path = path.substring(1, path.length())  
  XEResource r = xeRMan.load(path)
  if(r!=null) {
         try{
           xe.run(r)
         }
         catch(e){
            out(e.getMessage())
         }
		 return null
   }
}
out("404: Not found")